#include<iostream>
using namespace std;
class CR
{
	private:
		int w,h;
		static int totalArea;
		static int totalNumber;
		public:
			CR(int w_,int h_);
			~CR();
			static void PT();
 };
 CR::CR(int w_,int h_)
 {
 	w=w_;h=h_;
 	totalNumber++;
 	totalArea+=w*h;
 }
 CR::~CR()
 {
 	totalNumber--;
 	totalArea-=w*h;
 }
 void CR::PT()
 {
 	cout<<totalNumber<<","<<totalArea<<endl;
 }
 int CR::totalNumber=0;
 int CR::totalArea=0;
 int main()
 {
 	CR r1(3,3),r2(2,2);
 	//cout<<CR::totalNumber;
 	CR::PT();
 	r1.PT();
 	return 0;
 }
